package com.my;

import com.my.thread.ClockInThread;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@MapperScan("com.my.mapper")
@SpringBootApplication
public class Application {

    private static ClockInThread clockInThread;

    @Autowired
    public void setClockInThread(ClockInThread clockInThread) {
        Application.clockInThread = clockInThread;
    }

    public static void main(String[] args) {
        SpringApplication.run(Application.class, args);
        clockInThread.start();
    }

}
